<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=7" />
<title>我的半价汇</title>
<meta content="衣服 美妆 包包 配饰 母婴 打折 5折" name="keywords" />
<meta content="每日帮您挑选淘宝最优质商家的促销活动。淘，每日从这里开始！" name="description" />
<link href="static/index/css/style.css" rel="stylesheet" type="text/css" />
<link href="static/index/css/div.css?t=<?php echo date("D"); ?>" rel="stylesheet" type="text/css" />
<script src="./static/js/jquery.min.js" type="text/javascript"></script> 
<script src="http://a.tbcdn.cn/apps/stargate/ac/js/proxy.js?t=<?php echo date("U"); ?>"></script>
</head>
<style>
.my_avatar {width:80px;height:80px;}
#previlige-list-box {
    overflow: hidden;
}
.previlige-list-item {
    border-bottom: 1px solid #E4E4DF;
    cursor: pointer;
    height: 40px;
    padding: 15px 0 15px 22px;
}
.previlige-list-item dl {
    position: relative;
}
.previlige-list-item dt, .previlige-list-item dd {
    position: absolute;
}
.previlige-list-item dt.pre-name {
    width: 500px;
}
.previlige-list-item .pre-name {
    color: #D0001F;
    font-size: 14px;
    font-weight: bold;
}
.previlige-list-item dt.pre-name a{
    color: #D0001F;
}
.previlige-list-item dd.pre-btn {
    right: 20px;
    top: 10px;
    width: 85px;
}

.ui-button {
    cursor: pointer;
    display: inline-block;
    overflow: visible;
    padding: 0;
    position: relative;
    text-align: center;
    text-decoration: none !important;
    vertical-align: middle;
}
.ui-button-lorange .ui-button-text, .ui-button-morange .ui-button-text, .ui-button-sorange .ui-button-text {
    font-family: tahoma,arial,"STHeiti",Hei,宋体,sans-serif;
    font-size: 14px;
    font-weight: 700;
}
.ui-button-lwhite, .ui-button-lwhite:hover, .ui-button-mwhite, .ui-button-mwhiter:hover, .ui-button-swhite, .ui-button-swhite:hover, .ui-button-text {
    background-color: transparent;
    background-image: url("https://i.alipayobjects.com/e/201112/2BDRs1RcuB.png");
    background-repeat: no-repeat;
}

.ui-button-lwhite .ui-button-text, .ui-button-mwhite .ui-button-text, .ui-button-swhite .ui-button-text {
    font-family: tahoma,arial,"STHeiti",Hei,宋体,sans-serif;
    font-size: 14px;
    font-weight: 700;
}
.ui-button-swhite {
    background-position: 0 -711px;
}
.ui-button-swhite .ui-button-text {
    background-position: right -831px;
    color: #595959;
    font-size: 12px;
    padding: 3px 14px 4px;
}
.ui-button-sorange .ui-button-text {
    background-position: right -771px;
    color: #FFFFFF;
    font-size: 12px;
    padding: 3px 14px 4px;
}
.ui-button-swhite {
    background-position: 0 -711px;
}
</style>
<body tracingsrc="bjh.jpg" tracingopacity="49">
<div class="wrap">
	<div class="top">
		<a href="/index.php" class="logo"></a>
		<div class="wbjgz"></div>
	</div>
	<div class="nav">
		<?php if($_SESSION['visitor_nick']) { ?><div class="mybjh"><a href="#"><!--我的半价汇--><?php echo $_SESSION['visitor_nick'];?></a></div><?php } ?>
		<ul class="nav_f"><li class="seltab"><a href="">首页</a></li><li><a href="<?php echo spUrl('activity', 'index', array('acid'=>3));?>">爱家 爱生活</a><s class="chnMovie"></s></li></ul>
		<div class="ul_s_box">
			<a href="<?php echo spUrl('main', 'index');?>" <?php if($today != 'on' && $catid==0) { ?>class="seltab"<?php } ?> >全部(<?php echo $total; ?>)</a><a href="<?php echo spUrl('main', 'index', array('today'=>'on'));?>" <?php if($today == 'on') {?>class="seltab"<?php } ?>>今日活动(<?php echo $today_total; ?>)</a><?php  foreach($arr_cat_num as $k=>$v) {?><a href="<?php echo spUrl('main', 'index', array('catid'=>$v['catid']));?>" <?php if($catid == $v['catid']) {?>class="seltab"<?php } ?>><?php echo $v['title']; ?>(<?php echo $v['nums']; ?>)</a><?php } ?>
		</div>
	</div>
</div>
<div class="wrap">
	<div class="p10">
		<div class="w700 fl">
			<?php if($db_collect_result) { ?>
				<div class="sl-linear ui-box-qy-title">你订阅的店铺服务商</div>
				<ul class="previlige-list-box">
				<?php foreach($db_collect_result as $k=>$v) { ?>
					<li class="previlige-list-item split">
						<dl>
						<dt class="pre-name"><a href="<?php echo $v[store_detail][alimama_url];?>" target="_blank"><?php echo $v[store_name]; ?></a></dt>
						<dd class="pre-btn"><a class="ui-button ui-button-swhite" href="<?php echo $v[store_detail][alimama_url];?>" target="_blank"><span class="ui-button-text">去看看</span></a></dd>
						</dl>
					</li>
				<?php } ?>
				</ul>
			<?php } else {  ?>
				<div class="sl-linear ui-box-qy-title">订阅喜欢的服务商，发现想要的</div>
				<ul class="previlige-list-box">
				<?php foreach($collect_result->collect_item as $k=>$v) { ?>
					<li class="previlige-list-item split">
						<dl>
						<dt class="pre-name"><a href="" target="_blank"><?php echo $v->title; ?></a></dt>
						<dd class="pre-btn"><a class="ui-button subscribe ui-button-swhite" storeid="<?php echo $v->item_numid; ?>" owner_nick="<?php echo $v->item_owner_nick ;?>"><span class="ui-button-text">+ 订阅</span></a></dd>
						</dl>
					</li>
				<?php } ?>
				</ul>
				<script type="text/javascript">
					$('.subscribe').click(function(){
						var store_id = $(this).attr('storeid');
						var owner_nick = $(this).attr('owner_nick');
						$.post("<?php echo spUrl('subscribe', 'subscribe_add'); ?>", {'store_id':store_id, 'owner_nick':owner_nick}, function(data){});
					})
				</script>
			<?php } ?>
		</div>
		<div class="w215 fr">
			<div class="box_bl">
				<div><img src="<?php echo $my_avatar;?>" class="my_avatar" /><span><?php echo $visitor_nick;?></span></div>
			</div>
			<div id="premium_box" class="box_bl" >
				<?php include 'tags/index_premium.html' ?>
			</div>
			 <div class="box_bl">
				<div class="clearfix"><h2>推荐活动</h2><div class="tj_ico"><img src="static/index/images/bjh_tj.jpg"/></div></div>
				<div class="p10 center">
					<a href="http://bangpai.taobao.com/group/thread/14718693-272845924.htm" target="_blank"><img src="images/ads/ad195_124.jpg" width="195" height="124" /></a>
				</div>
			 </div>
		</div>
		<div class="h_1"></div>
	</div>
</div>
</body>
</html>
